#include<iostream>
#include<cstdio>
using namespace std;
int main(){
	int m , n ;
	double sum = 1.0;
	long long r = 1;
	cin >> n;
	for(int i = 1; i <= n; i++){
		r *= i; 
		sum += 1.0/r;
	}
	printf("%.10lf",sum);
	return 0;
}
